home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Java Primer Plus
/
Java Primer Plus (Waite Group Proess)(1996).iso
/
chapter9
/
neighbor.java
< prev
next >
Wrap
Text File
|
1995-12-31
|
593b
|
26 lines
// package aliens;
import brothers.Dad;
import brothers.UncleFrank;
import kids.Son;
// -------------- The nosy_neighbor Class ------------- //
class nosy_neighbor {
static public void main(String args[]) {
Dad a_dad = new Dad();
Son a_son = new Son();
// a_dad.sportscar = true; // ERROR!
// a_dad.fishing_boat = true; // ERROR!
// a_dad.golf_clubs = true; // ERROR!
// a_dad.familycar = true; // ERROR!
a_dad.lawnmower = true;
a_son.lawnmower = true; // Son says ok too
// a_dad.pubprot=true;
}
}